package com.xiaomo.gitee.datamanager.mapper;
import java.util.Collection;
import java.util.List;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.xiaomo.gitee.datamanager.entity.Imagedes;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

@Mapper
public interface ImagedesMapper extends BaseMapper<Imagedes> {

    Imagedes selectById(@Param("id") String id);

    int insertBatch(@Param("imagedesCollection") Collection<Imagedes> imagedesCollection);

    @Delete("DELETE FROM IMAGEDES WHERE id IN (SELECT id FROM IMAGES WHERE classification = #{classification})")
    int deleteByCategory(@Param("classification") Long classification);


}




